import type { AntdIconProps } from "@ant-design/icons/lib/components/AntdIcon"
export interface navBreadcrumb {
  key:string,
  icon:AntdIconProps,
  label:string
}

export type addCompany= {
  name:string,
  account:string,
  bank_name:string,
  is_active: true | false
}

export type CompanyList = {
  id:string,
  name:string
  account:string
  bank_name:string
  is_active: boolean
  createdAt:string
  updatedAt:string
}

export type CompanyItem = Omit<CompanyList, 'is_active' | 'createdAt' | 'updatedAt'>;
export type CompanyId = Omit<CompanyItem,'id'>

// 新增历史记录类型
export type HistoryCompany = {
  year:number,
  month:number,
  day:number,
  name:string
  account:string
  amount:number
  bank_name:string
  remark:string
}

// 新增历史记录类型 data
export type HistoryData = {
  data:HistoryCompany[]
}

// 获取历史记录列表类型
export type GetHistoryCompanyList = {
  id:number
  year:number,
  month:number,
  day:number,
  name:string
  account:string
  amount:number
  bank_name:string
  remark:string
  created_at:Date
  updated_at:Date
}

export type GetHistoryChildrenData = {
  info:GetHistoryCompanyList[]
}
export type GetHistoryData = {
  data:GetHistoryCompanyList[]
}

// 分组式历史记录列表
export type GroupHistoryData = {
  [key:string]:GetHistoryCompanyList[]
}

export type DownloadHistoryRecord = {
  create_at:string
  key:string,
  total:number,
  info:GetHistoryCompanyList[]
}